#ifndef CORE_EXEPTION_CLASS
#define CORE_EXEPTION_CLASS
#include <iostream>
#include <string>
#include <map>
#include <fstream>

namespace pland
{
///Fatal error
#define PEXP_FATAL 		1 << 0

///Retry required
#define PEXP_RETRY 		1 << 1

///Unallocated
#define PEXP_USER  		1 << 2

///Unallocated
#define PEXP_BAD_CONFIG 1 << 3

/*! \brief A core Exeption. This class is used as a default exception in the core code. */

class Exeption
{
public:
    /*!
     * Default Constructor
     * \param text text describing the origin
     * \param code the exeption code see PEXP_ definitions
     * */
    Exeption(std::string text, int code);

    /*!
     * Default destructor
     * */
    ~Exeption();

    /*!
     * Get the error description
     * \return error description string
     * */
    std::string get_error();

    /*! publicly available error code this code can be modified as the exception travels
     * trough the program
     * */
    unsigned int _error_status;
private:
    /*! exception text */
    const std::string exeption_text_;
};

}


#endif /*coreexeption.hpp*/
